# ctypes的库
from ctypes import *
from ctypes import windll
import os
# class Extern:
#     def __init__()
# 加载so库
os.system("gcc -fPIC -shared test.c -o libtest.so")
# lib_main = CDLL('./libtest.so')  # CDLL加载库1

  # CDLL加载库2
# target = windll.LoadLibrary("./libtarget.dll")
sum_value = lib_main.sum(10, 20)

print(sum_value)
os.system("rm ./libtest.so")

